package com.moogene.android;
import android.content.res.Resources;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.drawable.Drawable;
import android.view.Display;
public class InfoMediator {
    private static Display sDis;
    private static int sWidth;
    private static int sHeight;

    public static void setDisplay(Display dis){
        sDis = dis;
        sWidth = dis.getWidth();
        sHeight = dis.getHeight();
    }

	public static int getScreenWidth(){
		return sWidth;
	}

	public static int getScreenHeight(){
		return sHeight;
	}

	private static Resources resHandler;

	public static Resources getResHandler(){
		return resHandler;
	}

	public static Drawable getDrawable(int resId){
	    return resHandler.getDrawable(resId);
	}

	public static void setResHandler(Resources res){
		resHandler = res;
	}

	public static Bitmap getBitmap(int resId){
		return BitmapFactory.decodeResource(resHandler, resId);
	}
}
